import request from '@/utils/request'

// 查询加班列表
export function listWorkovertime(query) {
  return request({
    url: '/business/workovertime/list',
    method: 'get',
    params: query
  })
}

// 查询加班详细
export function getWorkovertime(id) {
  return request({
    url: '/business/workovertime/' + id,
    method: 'get'
  })
}

// 新增加班
export function addWorkovertime(data) {
  return request({
    url: '/business/workovertime',
    method: 'post',
    data: data
  })
}

// 修改加班
export function updateWorkovertime(data) {
  return request({
    url: '/business/workovertime',
    method: 'put',
    data: data
  })
}

// 删除加班
export function delWorkovertime(id) {
  return request({
    url: '/business/workovertime/' + id,
    method: 'delete'
  })
}

// 导出加班
export function exportWorkovertime(query) {
  return request({
    url: '/business/workovertime/export',
    method: 'get',
    params: query
  })
}